﻿
using System.Data.Linq;
using System.Collections.Generic;
using System.Data.Linq.Mapping;

namespace Chromatics
{
    public class UserSettingsDataContext : DataContext
    {
        public UserSettingsDataContext(string connectionString)
            : base(connectionString)
        {
        }
        public Table<UserSetting> UserInfo
        {
            get
            {
                return this.GetTable<UserSetting>();
            }
        }
        public Table<Levels> Levels
        {
            get
            {
                return this.GetTable<Levels>();
            }
        }
    }

    [Table]
    public class UserSetting
    {
        [Column(IsPrimaryKey = true)]
        public int ID
        {
            get;
            set;
        }
        [Column(CanBeNull = false)]
        public bool Sound
        {
            get;
            set;
        }
        [Column(CanBeNull = false)]
        public bool Music
        {
            get;
            set;
        }
    }

    [Table]
    public class Levels
    {
        [Column(IsPrimaryKey = true)]
        public int ID
        {
            get;
            set;
        }
        [Column(CanBeNull = false)]
        public string Status
        {
            get;
            set;
        }
        [Column(CanBeNull = false)]
        public string Difficulty
        {
            get;
            set;
        }
        [Column(CanBeNull = false)]
        public int Number
        {
            get;
            set;
        }
    }
}
